package chapter01_stackandqueue;

import java.util.Objects;

/**
 * 描述：
 *
 * @author hl
 * @date 2021/1/20 9:54
 */
public class Node {
    public int value;
    public Node left;
    public Node right;


    public Node(int value) {
        this.value = value;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Node treeNode = (Node) o;
        return value == treeNode.value;
    }

    @Override
    public int hashCode() {
        return Objects.hash(value);
    }
}
